package com.kx.center.mappers;

import java.util.HashMap;
import java.util.List;

import org.apache.ibatis.annotations.Param;

import com.kx.center.entity.Goods;

public interface GoodsMapper {
	
	public int insertGoods(Goods goods);
	public int updateGoods(Goods goods);
	
	//根据门店id获取商品列表
	public List<Goods> findGoodsByStoreId(Integer storeId);
	public List<Goods> findGoodsByStoreIdAndTypeId(@Param("storeId")Integer storeId, @Param("typeId")Integer typeId);
	//查询good类型
	public List<HashMap<String, Object>> findAllGoodsType();

	public void updateGoodsStorage(@Param("storeId")Integer storeId, @Param("goodsId")Integer goodsId, @Param("storage")Integer storage);
	public void updateGoodsRefStorage(@Param("storeId")Integer storeId, @Param("goodsId")Integer goodsId, @Param("storage")Integer storage);

	public List<HashMap<String, Object>> findYestodayOrderedQuantityById(@Param("storeId")Integer storeId,@Param("date")String date);
	
	public List<HashMap<String, Object>> findYestodaySelledQuantityById(@Param("storeId")Integer storeId,@Param("date")String date);
}
